<template>
  <div id="app">
    <!--<div class="table-num">-->
    <!--A大厅-08桌-->
    <!--</div>-->
    <div class="content">
      <router-view v-if="isRouterAlive"/>
    </div>
  </div>
</template>

<script>
  // import axios from 'axios';
  // import {basePath} from './api/api_const';
  export default {
    name: 'App',
    provide() {
      return {
        reload: this.reload
      }
    },
    data() {
      return {
        isRouterAlive: true
      }
    },
    methods: {
      reload() {
        this.isRouterAlive = false;
        this.$nextTick(function () {
          this.isRouterAlive = true;
        })
      }
    },
    mounted() {
      document.title = localStorage.getItem('tablename');// 替换网页title
    }
  }
</script>

<style lang="scss">
  /*初始化样式*/
  body, ol, ul, h1, h2, h3, h4, h5, h6, p, th, td, dl, dd, form, fieldset, legend, input, textarea, select {
    margin: 0;
    padding: 0
  }

  body {
    font: 12px "宋体", "Arial Narrow", HELVETICA;
    background: #fff;
    -webkit-text-size-adjust: 100%;
  }

  a {
    color: #2d374b;
    text-decoration: none
  }

  a:hover {
    color: #cd0200;
    text-decoration: underline
  }

  em {
    font-style: normal
  }

  li {
    list-style: none
  }

  img {
    border: 0;
    vertical-align: middle
  }

  table {
    border-collapse: collapse;
    border-spacing: 0
  }

  p {
    word-wrap: break-word
  }

  /*样式*/
  /*.table-num {*/
  /*position: absolute;*/
  /*width: 100%;*/
  /*top: 0;*/
  /*z-index: 2001;*/
  /*height: 40px;*/
  /*line-height: 40px;*/
  /*text-align: center;*/
  /*font-size: 18px;*/
  /*border-bottom: 1px solid #efefef;*/
  /*}*/
  body {
    overflow-x: hidden;
  }

  .content {
    position: absolute;
    width: 100%;
    top: 0;
    bottom: 0;
  }
</style>
